
import yaml


def read_yaml(filename):

    # 读取文件
    file  = open(file=filename,mode="rb")

    # 将文件转换字典格式
    data = yaml.load(file,Loader=yaml.SafeLoader)

    return data



#
# print(read_yaml("../data/login.yaml"))
# print(type(read_yaml("../data/login.yaml")))
# print(read_yaml("../data/bankcard_add.yaml"))
# print(read_yaml("../data/ceshi_login.yaml"))
# print(type(read_yaml("../data/ceshi_login.yaml")))

# args = read_yaml("../data/buy.yaml")
# print(args)
# print(type(args[0]))
# print(args[0]['method'])

# print(read_yaml("../data/ceshi_buy_login.yaml"))




